<!DOCTYPE html>
<html lang="zh">
<head>
	<meta charset="UTF-8" />
	<meta name="viewport" content="width=device-width, initial-scale=1.0" />
	<meta http-equiv="X-UA-Compatible" content="ie=edge" />
	<title>Document</title>
	
	
	<link rel='stylesheet' th:href="@{~/3thExt/bootstrap/bootstrap-3.3.7-dist/css/bootstrap.min.css}" href="../../static/3thExt/bootstrap/bootstrap-3.3.7-dist/css/bootstrap.min.css" />
	<link rel='stylesheet' th:href="@{~/3thExt/bootstrap-table/1.12.1/bootstrap-table.min.css}" href="../../static/3thExt/bootstrap-table/1.12.1/bootstrap-table.min.css"/>
	<link rel='stylesheet' th:href="@{~/3thExt/select2/4.0.6/css/select2.css}" href="../../static/3thExt/select2/4.0.6/css/select2.css"/>
	<link rel='stylesheet' th:href="@{~/3thExt/bootstrapvalidator/0.5.2/css/bootstrapValidator.min.css}" href="../../static/3thExt/bootstrapvalidator/0.5.2/css/bootstrapValidator.min.css"/>
	<link rel='stylesheet' th:href="@{~/3thExt/bootstrap-fileinput/4.4.7/css/fileinput.min.css}" href="../../static/3thExt/bootstrap-fileinput/4.4.7/css/fileinput.min.css"/>
	<link rel='stylesheet' th:href="@{~/3thExt/bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css}" href="../../static/3thExt/bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css"/>
	<link rel='stylesheet' th:href="@{~/css/icon-zc.css}" href="../../static/css/icon-zc.css"/>
	<link rel='stylesheet' th:href="@{~/css/style.css}" href="../../static/css/style.css"/>
	
	
</head>
<body>
<!--头部-->
<header th:replace="common/head" >
</header> 
<!-- 页面指向 -->
<div th:replace="common/title">
</div>
<!-- 菜单树 -->
<div th:replace="common/left" > 
</div>




<!--主体内容-->
<div class="page-container">

	<div class="container-fluid mb-20 clearfix">
		<div class="col-md-12">
			<h2 class="page-section-title">查询条件</h2>
		</div>
	</div>

	<div class="container-fluid query-frame-wrap mb-10 clearfix">
		<div class="col-lg-9 col-lg-item-6">
			<div class="row">
				<div class="col-lg-4">
					<div class="query-frame">
						<label>设备类别编号</label>
						<select name="" id="e21">
							<option value="">1</option>
							<option value="">1</option>
						</select>
					</div>
				</div>
				<div class="col-lg-4">
					<div class="query-frame">
						<label>设备类型</label>
						<input autocomplete="new-password" type="text" class="form-control" />
					</div>
				</div>
				<div class="col-lg-4">
					<div class="query-frame">
						<label>设备变量参数</label>
						<input autocomplete="new-password" type="text" class="form-control" />
					</div>
				</div>
			</div>
			<div class="row">
				<div class="col-lg-4">
					<div class="query-frame">
						<label>设备变量参数</label>
						<input autocomplete="new-password" type="text" class="form-control" />
					</div>
				</div>
				<div class="col-lg-4">
					<div class="query-frame">
						<label>设备变量参数</label>
						<input autocomplete="new-password" type="text" class="form-control" />
					</div>
				</div>
				<div class="col-lg-4">
					<div class="query-frame">
						<label>设备变量参数</label>
						<input autocomplete="new-password" type="text" class="form-control" />
					</div>
				</div>
			</div>
		</div>
		<div class="col-lg-3">
			<div class="query-frame query-button">
				<img src="../../static/image/search.png"/>
				<img src="../../static/image/rest.png"/>
			</div>
		</div>
	</div>

	<div class="container-fluid mb-20 clearfix">
		<div class="col-md-12 rlt">
			<h2 class="page-section-title">设备参数列表</h2>
			<ul class="table-tool">
			    <li data-toggle="modal" data-target="#myModal">
			        <span class="icon-list_add" aria-hidden="true"></span>
			        <label>新增</label>
			    </li>
			    <li>
			        <span class="icon-list_xiugai" aria-hidden="true"></span>
			        <label>修改</label>
			    </li>
			    <li>
			        <span class="icon-list_shanchu" aria-hidden="true"></span>
			        <label>删除</label>
			    </li>
			    <li>
			        <span class="icon-list_shuaxin" aria-hidden="true"></span>
			        <label>刷新</label>
			    </li>
			</ul>
		</div>
	</div>

	<div class="container-fluid table-container">
		<table id="table">

		</table>
	</div>
</div>

<!--模态框-表单验证和文件上传-->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog">
  <div class="modal-dialog" role="document">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title">Newly added</h4>
      </div>
      <div class="modal-body">
		    <div class="row">
		        <div class="col-lg-12">
		            <form id="defaultForm" method="" class="form-horizontal" action="">
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-6">设备类别编号</label>
		                    <div class="col-lg-7">
		                    	<select name="" class="form-control">
		                    		<option value="">1</option>
		                    	</select>
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-4">设备类型</label>
		                    <div class="col-lg-7">
		                    	<input autocomplete="new-password" type="text" disabled="disabled" class="form-control" name="" id="" value="" />
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-6">设备变量参数</label>
		                    <div class="col-lg-7">
		                    	<input autocomplete="new-password" type="text" class="form-control" name="" id="" value="" />
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-4">采集方式</label>
		                    <div class="col-lg-7">
		                    	<select name="" class="form-control">
		                    		<option value="">PLC</option>
		                    		<option value="">文件</option>
		                    		<option value="">数据库</option>
		                    		<option value="">上机</option>
		                    	</select>
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-5">PLC地址</label>
		                    <div class="col-lg-7">
		                    	<input autocomplete="new-password" type="text" class="form-control" name="" id="" value="" />
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-4">工艺范围</label>
		                    <div class="col-lg-7">
		                    	<input autocomplete="new-password" type="text" class="form-control" name="" id="" value="" />
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-4">缩放地址</label>
		                    <div class="col-lg-7">
		                    	<input autocomplete="new-password" type="text" class="form-control" name="" id="" value="" />
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-4">数据类型</label>
		                    <div class="col-lg-7">
		                    	<select name="" class="form-control">
									<option value="short">16位有符号整数</option>
									<option value="uint">32位无符号整数</option>
									<option value="int">32位有符号整数</option>
									<option value="long">64位有符号整数</option>
									<option value="float">4字节IEEE单精度浮点数</option>
									<option value="double">8字节IEEE双精度浮点数</option>
									<option value="bool">布尔型</option>
									<option value="byte">8位无符号整数</option>
		                    	</select>
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-4">读写属性</label>
		                    <div class="col-lg-7">
		                    	<select name="" class="form-control">
									<option value="0">只读</option>
									<option value="1">只写</option>
									<option value="2">可读可写</option>
		                    	</select>
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-6">是否自动告警</label>
		                    <div class="col-lg-7">
		                    	<select name="" class="form-control">
		                    		<option value="">是</option>
		                    		<option value="">否</option>
		                    	</select>
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-6">告警名称定义</label>
		                    <div class="col-lg-7">
		                    	<input autocomplete="new-password" class="form-control" type="text" disabled="disabled" name="" id="" value="" />
		                    </div>
		                </div>
		                <div class="form-group">
		                    <label class="col-lg-3 control-label form-required form-required-5">SPC标准值</label>
		                    <div class="col-lg-7">
		                    	<input autocomplete="new-password" class="form-control" type="text" name="" id="" value="" />
		                    </div>
		                </div>
		            </form>
		        </div>
		    </div>
      </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
        <button type="button" class="btn btn-primary">Save changes</button>
      </div>
    </div>
  </div>
</div>

<script th:src="@{/3thExt/jquery/3.3.1/jquery-3.3.1.min.js}" src="../../static/3thExt/jquery/3.3.1/jquery-3.3.1.min.js"></script>
<script th:src="@{/3thExt/jquery-form/3.46/jquery.form.js}" src="../../static/3thExt/jquery-form/3.46/jquery.form.js"></script>
<script th:src="@{/3thExt/bootstrap/bootstrap-3.3.7-dist/js/bootstrap.min.js}" src="../../static/3thExt/bootstrap/bootstrap-3.3.7-dist/js/bootstrap.min.js"></script>
<script th:src="@{/3thExt/bootstrap-table/1.12.1/bootstrap-table.min.js}" src="../../static/3thExt/bootstrap-table/1.12.1/bootstrap-table.min.js"></script>
<script th:src="@{/3thExt/bootstrap-table/1.12.1/locale/bootstrap-table-zh-CN.min.js}" src="../../static/3thExt/bootstrap-table/1.12.1/locale/bootstrap-table-zh-CN.min.js"></script>
<script th:src="@{/3thExt/select2/4.0.6/js/select2.js}" src="../../static/3thExt/select2/4.0.6/js/select2.full.js"></script>
<script th:src="@{/3thExt/bootstrapvalidator/0.5.2/js/bootstrapValidator.min.js}" src="../../static/3thExt/bootstrapvalidator/0.5.2/js/bootstrapValidator.min.js"></script>
<script th:src="@{/3thExt/bootstrap-fileinput/4.4.7/js/fileinput.min.js}" src="../../static/3thExt/bootstrap-fileinput/4.4.7/js/fileinput.min.js"></script>
<script th:src="@{/3thExt/bootstrap-fileinput/4.4.7/js/locales/zh.js}" src="../../static/3thExt/bootstrap-fileinput/4.4.7/js/locales/zh.js"></script>
<script th:src="@{/3thExt/bootstrap-datetimepicker/js/bootstrap-datetimepicker.min.js}" src="../../static/3thExt/bootstrap-datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
<script th:src="@{/3thExt/bootstrap-datetimepicker/js/bootstrap-datetimepicker.zh-CN.js}" src="../../static/3thExt/bootstrap-datetimepicker/js/bootstrap-datetimepicker.zh-CN.js"></script>
<script th:src="@{/js/page-interaction.js}" src="../../static/js/page-interaction.js"></script>


<script type="text/javascript">

$(function () {
//--------------------------------------------时间设置--------------------------------------------	
	$(".form_datetime").datetimepicker({format: 'yyyy-mm-dd hh:ii'});
//--------------------------------------------搜索下拉框设置--------------------------------------------
    $('#e21').select2({});
	$('#modal-select').select2({});
//--------------------------------------------表单验证设置--------------------------------------------
    $('#defaultForm')
        .bootstrapValidator({
            message: 'This value is not valid',
            feedbackIcons: {
                valid: 'glyphicon glyphicon-ok',
                invalid: 'glyphicon glyphicon-remove',
                validating: 'glyphicon glyphicon-refresh'
            },
            fields: {
                username: {
                    message: 'The username is not valid',
                    validators: {
                        notEmpty: {
                            message: 'The username is required and can\'t be empty'
                        },
                        stringLength: {
                            min: 6,
                            max: 30,
                            message: 'The username must be more than 6 and less than 30 characters long'
                        },
                        /*remote: {
                            url: 'remote.php',
                            message: 'The username is not available'
                        },*/
                        regexp: {
                            regexp: /^[a-zA-Z0-9_\.]+$/,
                            message: 'The username can only consist of alphabetical, number, dot and underscore'
                        }
                    }
                },
                email: {
                    validators: {
                        notEmpty: {
                            message: 'The email address is required and can\'t be empty'
                        },
                        emailAddress: {
                            message: 'The input is not a valid email address'
                        }
                    }
                },
                password: {
                    validators: {
                        notEmpty: {
                            message: 'The password is required and can\'t be empty'
                        }
                    }
                }
            }
        })
        .on('success.form.bv', function(e) {
            // Prevent form submission
            e.preventDefault();

            // Get the form instance
            var $form = $(e.target);

            // Get the BootstrapValidator instance
            var bv = $form.data('bootstrapValidator');

            // Use Ajax to submit form data
            $.post($form.attr('action'), $form.serialize(), function(result) {
                console.log(result);
            }, 'json');
        });
//--------------------------------------------文件上传设置--------------------------------------------
	$("#uploadfile").fileinput({

        language: 'zh', //设置语言

        uploadUrl:"http://127.0.0.1/testDemo/fileupload/upload.do", //上传的地址

       allowedFileExtensions: ['jpg', 'gif', 'png'],//接收的文件后缀

       //uploadExtraData:{"id": 1, "fileName":'123.mp3'},

        uploadAsync: true, //默认异步上传

        showUpload:true, //是否显示上传按钮

        showRemove :true, //显示移除按钮

        showPreview :true, //是否显示预览

        showCaption:false,//是否显示标题

        browseClass:"btn btn-primary", //按钮样式    

       dropZoneEnabled: false,//是否显示拖拽区域

       //minImageWidth: 50, //图片的最小宽度

       //minImageHeight: 50,//图片的最小高度

       //maxImageWidth: 1000,//图片的最大宽度

       //maxImageHeight: 1000,//图片的最大高度

        //maxFileSize:0,//单位为kb，如果为0表示不限制文件大小

       //minFileCount: 0,

        maxFileCount:10, //表示允许同时上传的最大文件个数

        enctype:'multipart/form-data',

       validateInitialCount:true,

        previewFileIcon: "<iclass='glyphicon glyphicon-king'></i>",

       msgFilesTooMany: "选择上传的文件数量({n}) 超过允许的最大数值{m}！",

   }).on("fileuploaded", function (event, data, previewId, index){
		
   });
})

</script>
</body>
</html>